(*
Source file: BasicAST.fs
October, 2012
Authors:	Jorge Fabian Maciel Hernandez	967153
		Esteban Perez Mejia		1163982

*)

module BASICAST

type Expr =
    | Number of int * float 
    | Identifier of int * string
    | IdentifierList of int * char * Expr 
    | IdentifierTable of int * char * Expr  * Expr
    | FunId of int * string
    | Minus of int * Expr * Expr
    | Plus of int * Expr * Expr
    | Times  of int * Expr * Expr
    | Div of int * Expr * Expr
    | Pow of int * Expr * Expr
    | MinEq of int * Expr * Expr
    | MaxEq of int * Expr * Expr 
    | NotEq of int * Expr * Expr
    | Min of int * Expr * Expr
    | Max of int * Expr * Expr
    | Equal of int * Expr * Expr
    | StdFun of int * string * Expr
    | UsrFun of int * string * Expr

type Stmt =
    | LetVar of int * int * string * Expr
    | LetList of int * int * char * Expr * Expr
    | LetTable of int * int * char * Expr * Expr * Expr
    | Rem of int * int
    | Stop of int * int
    | End of int * int
    | If of int * int * Expr * string * Expr * int
    | Data of int * int * string list
    | Def of int * int * string * string * Expr
    | Goto of int * int * int
    | Print of int * int * (string option * Expr option * bool) list
    | GoSub of int * int * int
    | Dim of int * int * (string * string * string option) list
    | Return of int * int
    | Read of int * int * (string * Expr option * Expr option) list
    | For of int * int * string * Expr * Expr * Expr option
    | Next of int * int * string



type Prog = Program of Stmt list
